cmake_minimum_required(VERSION 3.15)
# 下载并解压第三方库
include(cmake/download_libraries.cmake)
download_libraries(libraries_url.ini)
if(EXISTS ${CMAKE_SOURCE_DIR}/libraries/vcpkg)
    set(CMAKE_TOOLCHAIN_FILE ${CMAKE_SOURCE_DIR}/libraries/vcpkg/scripts/buildsystems/vcpkg.cmake)
    message(STATUS "Using vcpkg toolchain file: ${CMAKE_TOOLCHAIN_FILE}")
endif()

project(cmake_demo)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_SOURCE_DIR}/bin)

find_package(spdlog CONFIG REQUIRED)

add_executable(main source/main.cpp)
target_link_libraries(main PRIVATE spdlog::spdlog_header_only)
